﻿
@{
    ViewBag.Title = "表单向导";
}

@section Style{
    @Styles.Render("~/Content/Flat/Css/FormWizard")
}

@section Script{
    @Scripts.Render("~/Content/Flat/Js/form_wizard")
<script>

      //step wizard

      $(function() {
          $('#default').stepy({
              backLabel: 'Previous',
              block: true,
              nextLabel: 'Next',
              titleClick: true,
              titleTarget: '.stepy-tab'
          });
      });
</script>

<script type="text/javascript">
      $(document).ready(function () {
          var form = $("#wizard-validation-form");
          form.validate({
              errorPlacement: function errorPlacement(error, element) {
                  element.after(error);
              }
          });
          form.children("div").steps({
              headerTag: "h3",
              bodyTag: "section",
              transitionEffect: "slideLeft",
              onStepChanging: function (event, currentIndex, newIndex) {
                  form.validate().settings.ignore = ":disabled,:hidden";
                  return form.valid();
              },
              onFinishing: function (event, currentIndex) {
                  form.validate().settings.ignore = ":disabled";
                  return form.valid();
              },
              onFinished: function (event, currentIndex) {
                  alert("Submitted!");
              }
          });


      });
</script>

}
<!--main content start-->
<section id="main-content">
    <section class="wrapper site-min-height">
        <!-- page start-->
        <div class="row">
            <div class="col-lg-12">
                <section class="panel">
                    <header class="panel-heading">
                        表单向导
                    </header>
                    <div class="panel-body">
                        <div class="stepy-tab">
                            <ul id="default-titles" class="stepy-titles clearfix">
                                <li id="default-title-0" class="current-step">
                                    <div>第一步</div>
                                </li>
                                <li id="default-title-1" class="">
                                    <div>第二步</div>
                                </li>
                                <li id="default-title-2" class="">
                                    <div>第三步</div>
                                </li>
                            </ul>
                        </div>
                        <form class="form-horizontal" id="default">
                            <fieldset title="第一步" class="step" id="default-step-0">
                                <legend> </legend>
                                <div class="form-group">
                                    <label class="col-lg-2 control-label">全称</label>
                                    <div class="col-lg-10">
                                        <input type="text" class="form-control" placeholder="全称">
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-lg-2 control-label">邮件地址</label>
                                    <div class="col-lg-10">
                                        <input type="text" class="form-control" placeholder="邮件地址">
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-lg-2 control-label">用户名</label>
                                    <div class="col-lg-10">
                                        <input type="text" class="form-control" placeholder="用户名">
                                    </div>
                                </div>

                            </fieldset>
                            <fieldset title="第二步" class="step" id="default-step-1">
                                <legend> </legend>
                                <div class="form-group">
                                    <label class="col-lg-2 control-label">电话</label>
                                    <div class="col-lg-10">
                                        <input type="text" class="form-control" placeholder="电话">
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-lg-2 control-label">移动电话</label>
                                    <div class="col-lg-10">
                                        <input type="text" class="form-control" placeholder="移动电话">
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-lg-2 control-label">地址</label>
                                    <div class="col-lg-10">
                                        <textarea class="form-control" cols="60" rows="5"></textarea>
                                    </div>
                                </div>

                            </fieldset>
                            <fieldset title="第三步" class="step" id="default-step-2">
                                <legend> </legend>
                                <div class="form-group">
                                    <label class="col-lg-2 control-label">全称</label>
                                    <div class="col-lg-10">
                                        <p class="form-control-static">Tawseef Ahmed</p>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-lg-2 control-label">邮件地址</label>
                                    <div class="col-lg-10">
                                        <p class="form-control-static">service@jucheap.com</p>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-lg-2 control-label">用户名</label>
                                    <div class="col-lg-10">
                                        <p class="form-control-static">tawseef</p>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-lg-2 control-label">电话</label>
                                    <div class="col-lg-10">
                                        <p class="form-control-static">01234567</p>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-lg-2 control-label">移动电话</label>
                                    <div class="col-lg-10">
                                        <p class="form-control-static">01234567</p>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <label class="col-lg-2 control-label">Address</label>
                                    <div class="col-lg-10">
                                        <p class="form-control-static">
                                            Dreamland Ave, Suite 73
                                            AU, PC 1361
                                            P: (123) 456-7891
                                        </p>
                                    </div>
                                </div>
                            </fieldset>
                            <input type="submit" class="finish btn btn-danger" value="完成" />
                        </form>
                    </div>
                </section>
            </div>
        </div>
        <div class="row">
            <div class="col-lg-12">
                <!--progress bar start-->
                <section class="panel">
                    <header class="panel-heading">
                        带验证的表单向导
                    </header>
                    <div class="panel-body">
                        <form id="wizard-validation-form" action="#">
                            <div>
                                <h3>第一步</h3>
                                <section>
                                    <div class="form-group clearfix">
                                        <label class="col-lg-2 control-label " for="userName">用户名 </label>
                                        <div class="col-lg-10">
                                            <input class="form-control" id="userName" name="userName" type="text" class="required">

                                        </div>
                                    </div>
                                    <div class="form-group clearfix">
                                        <label class="col-lg-2 control-label " for="password"> 密码 *</label>
                                        <div class="col-lg-10">
                                            <input id="password" name="password" type="text" class="required form-control">

                                        </div>
                                    </div>

                                    <div class="form-group clearfix">
                                        <label class="col-lg-2 control-label " for="confirm">确认密码 *</label>
                                        <div class="col-lg-10">
                                            <input id="confirm" name="confirm" type="text" class="required form-control">
                                        </div>
                                    </div>
                                    <div class="form-group clearfix">
                                        <label class="col-lg-12 control-label ">(*) 必填</label>
                                    </div>
                                </section>
                                <h3>第二步</h3>
                                <section>

                                    <div class="form-group clearfix">
                                        <label class="col-lg-2 control-label" for="name"> 姓 *</label>
                                        <div class="col-lg-10">
                                            <input id="name" name="name" type="text" class="required form-control">
                                        </div>
                                    </div>
                                    <div class="form-group clearfix">
                                        <label class="col-lg-2 control-label " for="surname"> 名 *</label>
                                        <div class="col-lg-10">
                                            <input id="surname" name="surname" type="text" class="required form-control">

                                        </div>
                                    </div>

                                    <div class="form-group clearfix">
                                        <label class="col-lg-2 control-label " for="email">邮箱 *</label>
                                        <div class="col-lg-10">
                                            <input id="email" name="email" type="text" class="required email form-control">
                                        </div>
                                    </div>

                                    <div class="form-group clearfix">
                                        <label class="col-lg-2 control-label " for="address">地址 </label>
                                        <div class="col-lg-10">
                                            <input id="address" name="address" type="text" class="form-control">
                                        </div>
                                    </div>

                                    <div class="form-group clearfix">
                                        <label class="col-lg-12 control-label ">(*) 必填</label>
                                    </div>

                                </section>
                                <h3>第三步</h3>
                                <section>
                                    <div class="form-group clearfix">
                                        <div class="col-lg-12">
                                            <ul class="list-unstyled w-list">
                                                <li>姓 : Mosaddek </li>
                                                <li>名 : Hossain </li>
                                                <li>邮箱: service@jucheap.com</li>
                                                <li>地址: 123 Dream City, Dreamland. </li>
                                            </ul>
                                        </div>
                                    </div>
                                </section>
                                <h3>最后一步</h3>
                                <section>
                                    <div class="form-group clearfix">
                                        <div class="col-lg-12">
                                            <input id="acceptTerms" name="acceptTerms" type="checkbox" class="required">
                                            <label for="acceptTerms">我同意用户协议.</label>
                                        </div>
                                    </div>

                                </section>
                            </div>
                        </form>
                    </div>
                </section>


            </div>


        </div>
        <!-- page end-->
    </section>
</section>
<!--main content end-->